ARD2  1.00 for Rev B. Hardware
Airbag Reference Demonstrator using MPC5604P
Error_State.h
Go to the documentation of this file.
00001 
00017 #ifndef ERROR_STATE_H_
00018 #define ERROR_STATE_H_
00019 
00020 /*
00021  **************************************************************
00022  * Defines, Macros and Typedefs 
00023  **************************************************************/
00024 /*** Constant Macros ***/
00025 /* Default Yes and No defines */
00026 #ifndef TRUE
00027  #define TRUE (1u)
00028 #endif
00029 #ifndef CLEAR
00030  #define CLEAR (0u)
00031 #endif
00032 #ifndef BITS_IN_NIBBLE
00033  #define BITS_IN_NIBBLE (4u)
00034 #endif
00035 #ifndef BITS_IN_BYTE
00036  #define BITS_IN_BYTE (8u)
00037 #endif
00038 #ifndef BYTES_IN_16
00039  #define BYTES_IN_16  (2u)
00040 #endif
00041 #ifndef BYTES_IN_32
00042  #define BYTES_IN_32  (4u)
00043 #endif
00044 
00045 #ifndef BIT_DEFINITION
00046  #define BIT_DEFINITION
00047  #define BIT0  (1u << 0u)
00048  #define BIT1  (1u << 1u)
00049  #define BIT2  (1u << 2u)
00050  #define BIT3  (1u << 3u)
00051  #define BIT4  (1u << 4u)
00052  #define BIT5  (1u << 5u)
00053  #define BIT6  (1u << 6u)
00054  #define BIT7  (1u << 7u)
00055  #define BIT8  (1u << 8u)
00056  #define BIT9  (1u << 9u)
00057  #define BIT10 (1u << 10)
00058  #define BIT11 (1u << 11)
00059  #define BIT12 (1u << 12)
00060  #define BIT13 (1u << 13)
00061  #define BIT14 (1u << 14)
00062  #define BIT15 (1u << 15)
00063  #define BIT16 (1u << 16)
00064  #define BIT17 (1u << 17)
00065  #define BIT18 (1u << 18)
00066  #define BIT19 (1u << 19)
00067  #define BIT20 (1u << 20)
00068  #define BIT21 (1u << 21)
00069  #define BIT22 (1u << 22)
00070  #define BIT23 (1u << 23)
00071  #define BIT24 (1u << 24)
00072  #define BIT25 (1u << 25)
00073  #define BIT26 (1u << 26)
00074  #define BIT27 (1u << 27)
00075  #define BIT28 (1u << 28)
00076  #define BIT29 (1u << 29)
00077  #define BIT30 (1u << 30)
00078  #define BIT31 (1u << 31)
00079 #endif
00080 /*** Function Macros ***/
00081 #ifndef N_ELEMENTS
00082  #define N_ELEMENTS(X)           (sizeof(X)/sizeof(*(X)))
00083 #endif
00084 
00085 /*** Enums ***/
00086 
00087 
00088 /*** TypeDefs ***/
00089 
00090 /*
00091  **************************************************************
00092  * Declarations 
00093  **************************************************************/
00094 /*** Global ***/
00095 /*** Static ***/
00096 
00097 /*** Constant ***/
00098 /*
00099  **************************************************************
00100  * Function Prototypes 
00101  **************************************************************/
00102 /*
00103  ******************************************************************************
00104  *
00105  * Function:          u32fnSafeMode()
00106  *
00107  */
00116 static uint32_t u32fnSafeMode(void);
00117 /*
00118  ******************************************************************************
00119  *
00120  * Function:          u32fnSMInitError()
00121  *
00122  */
00129 static uint32_t u32fnSMInitError(void);
00130 /*
00131  ******************************************************************************
00132  *
00133  * Function:          u32fnStateErrorError()
00134  *
00135  */
00142 static uint32_t u32fnStateErrorError(void);
00143 /*
00144  ******************************************************************************
00145  *
00146  * Function:          u32fnStateAcquisitionError()
00147  *
00148  */
00155 static uint32_t u32fnStateAcquisitionError(void);
00156 /*
00157  ******************************************************************************
00158  *
00159  * Function:          u32fnStateDecisionError()
00160  *
00161  */
00168 static uint32_t u32fnStateDecisionError(void);
00169 /*
00170  ******************************************************************************
00171  *
00172  * Function:          u32fnStateDeploymentError()
00173  *
00174  */
00181 static uint32_t u32fnStateDeploymentError(void);
00182 /*
00183  ******************************************************************************
00184  *
00185  * Function:          u32fnStateSystemTestError()
00186  *
00187  */
00194 static uint32_t u32fnStateSystemTestError(void);
00195 /*
00196  ******************************************************************************
00197  *
00198  * Function:          u32fnStateGUIError()
00199  *
00200  */
00207 static uint32_t u32fnStateGUIError(void);
00208 /*
00209  ******************************************************************************
00210  *
00211  * Function:          u16fnErrorRemoveFromList()
00212  *
00213  */
00223 static uint16_t u16fnErrorRemoveFromList(uint16_t u16Original, 
00224                                          uint16_t u16Failed);
00225 /*
00226  ******************************************************************************
00227  *
00228  * Function:          vfnDisplayGUIErrorMessage()
00229  *
00230  */
00238 static void vfnDisplayGUIErrorMessage(void);
00239 #endif /* ERROR_STATE_H_ */